import React from 'react';
import { Router, Route, Switch } from 'dva/router';
import IndexPage from './routes/IndexPage';
import Login from './routes/login';
import zhCN from 'antd/lib/locale-provider/zh_CN';
// import 'moment/locale/zh-cn';
import { LocaleProvider } from 'antd';


function RouterConfig({ history }) {
 
  return (
    <LocaleProvider locale={zhCN}>
    <Router history={history}>
      <Switch>
        <Route path='/' exact component={Login} />
        <Route path="/" component={IndexPage}  />
      </Switch>
    </Router>
    </LocaleProvider>
  );
}
export default RouterConfig;
